\(\int (e x)^m (a+b x) (a c-b c x) \, dx\) [71]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 20, antiderivative size = 42 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=\frac {a^2 c (e x)^{1+m}}{e (1+m)}-\frac {b^2 c (e x)^{3+m}}{e^3 (3+m)} \]

[Out]

a^2*c*(e*x)^(1+m)/e/(1+m)-b^2*c*(e*x)^(3+m)/e^3/(3+m)

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {74, 14} \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=\frac {a^2 c (e x)^{m+1}}{e (m+1)}-\frac {b^2 c (e x)^{m+3}}{e^3 (m+3)} \]

[In]

Int[(e*x)^m*(a + b*x)*(a*c - b*c*x),x]

[Out]

(a^2*c*(e*x)^(1 + m))/(e*(1 + m)) - (b^2*c*(e*x)^(3 + m))/(e^3*(3 + m))

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 74

Int[((a_) + (b_.)*(x_))^(m_.)*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[(a*c + b*
d*x^2)^m*(e + f*x)^p, x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && EqQ[b*c + a*d, 0] && EqQ[n, m] && Integer
Q[m] && (NeQ[m, -1] || (EqQ[e, 0] && (EqQ[p, 1] ||  !IntegerQ[p])))

Rubi steps \begin{align*} \text {integral}& = \int (e x)^m \left (a^2 c-b^2 c x^2\right ) \, dx \\ & = \int \left (a^2 c (e x)^m-\frac {b^2 c (e x)^{2+m}}{e^2}\right ) \, dx \\ & = \frac {a^2 c (e x)^{1+m}}{e (1+m)}-\frac {b^2 c (e x)^{3+m}}{e^3 (3+m)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.04 (sec) , antiderivative size = 31, normalized size of antiderivative = 0.74 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=c x (e x)^m \left (\frac {a^2}{1+m}-\frac {b^2 x^2}{3+m}\right ) \]

[In]

Integrate[(e*x)^m*(a + b*x)*(a*c - b*c*x),x]

[Out]

c*x*(e*x)^m*(a^2/(1 + m) - (b^2*x^2)/(3 + m))

Maple [A] (verified)

Time = 0.03 (sec) , antiderivative size = 41, normalized size of antiderivative = 0.98

method result size
norman \(\frac {a^{2} c x \,{\mathrm e}^{m \ln \left (e x \right )}}{1+m}-\frac {b^{2} c \,x^{3} {\mathrm e}^{m \ln \left (e x \right )}}{3+m}\) \(41\)
gosper \(\frac {c \left (e x \right )^{m} \left (-m \,x^{2} b^{2}-b^{2} x^{2}+a^{2} m +3 a^{2}\right ) x}{\left (3+m \right ) \left (1+m \right )}\) \(47\)
risch \(\frac {c \left (e x \right )^{m} \left (-m \,x^{2} b^{2}-b^{2} x^{2}+a^{2} m +3 a^{2}\right ) x}{\left (3+m \right ) \left (1+m \right )}\) \(47\)
parallelrisch \(-\frac {x^{3} \left (e x \right )^{m} b^{2} c m +x^{3} \left (e x \right )^{m} b^{2} c -x \left (e x \right )^{m} a^{2} c m -3 x \left (e x \right )^{m} a^{2} c}{\left (3+m \right ) \left (1+m \right )}\) \(66\)

[In]

int((e*x)^m*(b*x+a)*(-b*c*x+a*c),x,method=_RETURNVERBOSE)

[Out]

a^2*c/(1+m)*x*exp(m*ln(e*x))-b^2*c/(3+m)*x^3*exp(m*ln(e*x))

Fricas [A] (verification not implemented)

none

Time = 0.23 (sec) , antiderivative size = 50, normalized size of antiderivative = 1.19 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=-\frac {{\left ({\left (b^{2} c m + b^{2} c\right )} x^{3} - {\left (a^{2} c m + 3 \, a^{2} c\right )} x\right )} \left (e x\right )^{m}}{m^{2} + 4 \, m + 3} \]

[In]

integrate((e*x)^m*(b*x+a)*(-b*c*x+a*c),x, algorithm="fricas")

[Out]

-((b^2*c*m + b^2*c)*x^3 - (a^2*c*m + 3*a^2*c)*x)*(e*x)^m/(m^2 + 4*m + 3)

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 134 vs. \(2 (34) = 68\).

Time = 0.23 (sec) , antiderivative size = 134, normalized size of antiderivative = 3.19 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=\begin {cases} \frac {- \frac {a^{2} c}{2 x^{2}} - b^{2} c \log {\left (x \right )}}{e^{3}} & \text {for}\: m = -3 \\\frac {a^{2} c \log {\left (x \right )} - \frac {b^{2} c x^{2}}{2}}{e} & \text {for}\: m = -1 \\\frac {a^{2} c m x \left (e x\right )^{m}}{m^{2} + 4 m + 3} + \frac {3 a^{2} c x \left (e x\right )^{m}}{m^{2} + 4 m + 3} - \frac {b^{2} c m x^{3} \left (e x\right )^{m}}{m^{2} + 4 m + 3} - \frac {b^{2} c x^{3} \left (e x\right )^{m}}{m^{2} + 4 m + 3} & \text {otherwise} \end {cases} \]

[In]

integrate((e*x)**m*(b*x+a)*(-b*c*x+a*c),x)

[Out]

Piecewise(((-a**2*c/(2*x**2) - b**2*c*log(x))/e**3, Eq(m, -3)), ((a**2*c*log(x) - b**2*c*x**2/2)/e, Eq(m, -1))
, (a**2*c*m*x*(e*x)**m/(m**2 + 4*m + 3) + 3*a**2*c*x*(e*x)**m/(m**2 + 4*m + 3) - b**2*c*m*x**3*(e*x)**m/(m**2
+ 4*m + 3) - b**2*c*x**3*(e*x)**m/(m**2 + 4*m + 3), True))

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 41, normalized size of antiderivative = 0.98 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=-\frac {b^{2} c e^{m} x^{3} x^{m}}{m + 3} + \frac {\left (e x\right )^{m + 1} a^{2} c}{e {\left (m + 1\right )}} \]

[In]

integrate((e*x)^m*(b*x+a)*(-b*c*x+a*c),x, algorithm="maxima")

[Out]

-b^2*c*e^m*x^3*x^m/(m + 3) + (e*x)^(m + 1)*a^2*c/(e*(m + 1))

Giac [A] (verification not implemented)

none

Time = 0.30 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.55 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=-\frac {\left (e x\right )^{m} b^{2} c m x^{3} + \left (e x\right )^{m} b^{2} c x^{3} - \left (e x\right )^{m} a^{2} c m x - 3 \, \left (e x\right )^{m} a^{2} c x}{m^{2} + 4 \, m + 3} \]

[In]

integrate((e*x)^m*(b*x+a)*(-b*c*x+a*c),x, algorithm="giac")

[Out]

-((e*x)^m*b^2*c*m*x^3 + (e*x)^m*b^2*c*x^3 - (e*x)^m*a^2*c*m*x - 3*(e*x)^m*a^2*c*x)/(m^2 + 4*m + 3)

Mupad [B] (verification not implemented)

Time = 0.36 (sec) , antiderivative size = 46, normalized size of antiderivative = 1.10 \[ \int (e x)^m (a+b x) (a c-b c x) \, dx=\frac {c\,x\,{\left (e\,x\right )}^m\,\left (a^2\,m+3\,a^2-b^2\,x^2-b^2\,m\,x^2\right )}{m^2+4\,m+3} \]

[In]

int((a*c - b*c*x)*(e*x)^m*(a + b*x),x)

[Out]

(c*x*(e*x)^m*(a^2*m + 3*a^2 - b^2*x^2 - b^2*m*x^2))/(4*m + m^2 + 3)